<!DOCTYPE html>
<HTML>
<HEAD><meta name="viewport" content="width=device-width, initial-scale=1">
<Title>DataAccelerator.setSubsetRange</Title>
<link type='text/css' rel='Stylesheet' href="maxchartapi.css" />
</HEAD>
<body bgcolor="#FFFFFF" text="#000000" topmargin="0" leftmargin="0" rightmargin="0" marginwidth="0" marginheight="0">

<p class="heading0">ChartDirector 7.0 (Java Edition)</p>
<p class="heading1"><a href="DataAccelerator.htm">DataAccelerator</a>.<wbr>setSubsetRange</p>
<hr class="separator">
<p class="heading2a">Usage</p>
<div class="content">
public void setSubsetRange(double xStart, double xEnd [, int resolution ])
</div>
<p class="heading2">Description</p>
<div class="content">
Set the data range used for chart plotting.<br><br>
For zoomable and scrollable chart, depending on the zoom level, only part of the data may be visible. The setSubsetRange method should be used to set the visible x range so that the DataAccelerator can supply the chart with the necessary data only.<br><br>
The <b>resolution</b> argument is a hint of the number of pixels available in the x direction for plotting the data. This argument avoids the DataAccelerator from providing too much data to the chart. For example, if only 600 pixels are available in the x direction, it is not necessary to provide 10 million points to the chart, as they will overlap and block each others and the vast majority would not be visible. The DataAccelerator employs a special algorithm that can reduce the data to match the resolution without noticeably affecting the shape of the plotted chart.
</div>
<p class="heading2">Arguments</p>
<div class="content">
<div style="width:100%;box-sizing:border-box;">
<table border="1" cellpadding="5" cellspacing="0" width="100%"> 
<tr>
<th width="19%">Argument</th><th width="19%">Default</th><th>Description</th>
</tr>
<tr>
<td>xStart</td><td>(Mandatory)</td><td>The x value at the start of the visible range.</td></tr><tr><td>xEnd</td><td>(Mandatory)</td><td>The x value at the end of the visible range.</td></tr><tr><td>resolution</td><td>0</td><td>The approximate number of pixels available in the x direction for plotting the chart. In the most common case that the x-axis is horizontal, this is the plot area width. If this argument is not provided, ChartDirector will automatically choose the resolution to use.</td>
</tr>
</table>
</div>
</div>
<p class="heading2">Return Value</p>
<div class="content">
None
</div>
<br><hr class="separator">
<div class="copyright">&copy; 2022 Advanced Software Engineering Limited. All rights reserved.</div>
</body>
</HTML>
